//
// Description: 随机打乱方法 shuffle
// Created by Loading on 2021/8/15.
//

#include <bits/stdc++.h>

using namespace std;

int main() {
    vector<int> vec = {1, 2, 3, 4, 5};
    // 获得 time-based seed
    unsigned seed = chrono::system_clock::now().time_since_epoch().count();

    // 打乱次数
    int n = 10;
    while (n--) {
        // 随机打乱
        shuffle(vec.begin(), vec.end(), default_random_engine(seed));

        for (auto &x : vec) {
            cout << x << " ";
        }
        cout << endl;
    }
}